home *** CD-ROM | disk | FTP | other *** search
/ Magnum One / Magnum One (Mid-American Digital) (Disc Manufacturing).iso / d12 / fgl105c.arc / 05-10.C < prev    next >
Encoding:
C/C++ Source or Header  |  1991-10-11  |  333 b   |  25 lines

  1. #define COLORS 256
  2.  
  3. main()
  4. {
  5.    int base;
  6.    int color;
  7.    int mode;
  8.    int x;
  9.  
  10.    mode = fg_getmode();
  11.    fg_setmode(19);
  12.  
  13.    x = 0;
  14.  
  15.    for (color = 0; color < COLORS; color++) {
  16.       fg_setcolor(color);
  17.       fg_rect(x,x,0,199);
  18.       x++;
  19.       }
  20.    fg_waitkey();
  21.  
  22.    fg_setmode(mode);
  23.    fg_reset();
  24. }
  25.